package com.panopset.game.card;

import com.panopset.game.card.CardDefinition.Face;
import com.panopset.game.card.CardDefinition.Suit;

/**
 *
 * @author Karl Dinwiddie
 *
 */
public class Card {

    private final CardDefinition cd;

    public Card(final CardDefinition cardDefinition) {
        cd = cardDefinition;
    }

    private boolean isHighlighted = false;

    public boolean isHighlighted() {
        return isHighlighted;
    }

    /**
     * @param value True iff card is to be highlighted when displayed.
     */
    public void setHighlighted(final boolean value) {
        isHighlighted = value;
    }
    private boolean isShowing = false;

    public boolean isShowing() {
        return isShowing;
    }

    public void hide() {
        isShowing = false;
    }

    public void show() {
        isShowing = true;
    }

    public Face getFace() {
        return cd.getFace();
    }

    public Suit getSuit() {
        return cd.getSuit();
    }

    public String name() {
        return cd.name();
    }
}
